package com.yjz.security.controller;

import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RestController;

@RestController
public class TestController {

    @GetMapping("/product/{name}")
    public String test(@PathVariable("name")String name){
        return "product"+name;
    }
    @GetMapping(value = "/order/{id}")
    public String testOrder(@PathVariable(name = "id",required = false)String name){
        return "order"+name;
    }
}
